/*
 * Copyright 2008 Les Hazlewood
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package org.pojodm.entity;

/**
 * @author Les Hazlewood
 * @since Apr 5, 2008 3:11:31 PM
 */
public interface Referenceable extends Identifiable {

    /**
     * Returns a succinct and readable <em>unique</em> String representation of this object.  Primarily used as
     * a convenience method when you don't necessarily want to show the id of the entity, which could be considered
     * less 'user friendly'.
     *
     * <p>For example, this is often useful in HTML drop down form fields:</p>
     * 
     * <p><code>&lt;option value="$referenceable.id"&gt;$referenceable.label&lt;/option&gt;</code></p>
     *
     * @return the unique 'user friendly' String representation of this <code>Identifiable</code> object.
     */
    String getLabel();
}
